home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1997 July: Mac OS SDK / Dev.CD Jul 97 SDK1.toast / Development Kits (Disc 1) / QuickDraw GX / Programming Stuff / Sample Code / Printing Samples / Extensions… / UserItems ƒ / About UserItems… next >
Encoding:
Text File  |  1995-04-10  |  1.4 KB  |  23 lines  |  [ttro/ttxt]

  1. About “UserItems”…
  2.  
  3. “UserItems” demonstrates how to support userItems within your print panel overrides in a way that works with the QuickDraw GX messaging system.
  4.  
  5. This printing extension installs a panel in the Print dialog containing a userItem.  The extension doesn't have any underlying functionality-- it simply draws a picture of an apple over the userItem, and inverts the picture as you click on it.  Updating is handled in a way that only updates the area of the userItem that needs to be.  (This is trickier than it sounds.)
  6.  
  7. You cannot simply use SetDItem to set the update routine for a userItem in a panel because the Dialog Manager will attempt to jump directly to your update routine without going through the Message Manager, your A5 world will not be set up, you'll have no access to your resources, and you won't be able to send or forward any printing messages.  And, that's all assuming that your update routine is still where the Dialog Manager thinks it is.
  8.  
  9. The code for this extension demonstrates an approach to handling userItems which is reliable and fairly straight-forward.
  10.  
  11. This extension shows:
  12.  
  13. • How to write an extension which installs a panel, handles panel events and uses the way-cool ‘xdtl’ resources.
  14.  
  15. • How to write an extension which properly supports userItems in a print panel.
  16.  
  17. • How to easily set up an A5 world so that you can access global data.
  18.  
  19. Dave Hersey
  20. Apple Developer Technical Support
  21.  
  22. 7/14/94
  23. v1.0